<?php
/**
 * 应用配置模型
 */

namespace app\api\model;


use app\common\model\BaseModel;
use think\db\exception\DataNotFoundException;
use think\db\exception\ModelNotFoundException;
use think\exception\DbException;

class AppConfig extends BaseModel {

    /**
     * 获取配置
     * @param $data1
     * @param $data2
     * @throws DataNotFoundException
     * @throws ModelNotFoundException
     * @throws DbException
     */
    public static function get_data(&$data1, &$data2, &$data3) {
        $data1 = db('app_config')->where('type', 1)->field('wechat_account,code_src,wechat_nickname,phone')->find();//联系客服
        $data2 = db('app_config')->where('type', 2)->field('code_src')->find();//我的推荐二维码
        $data3 = db('app_config')->where('type', 3)->field('wechat_account,code_src')->find();//服务号
    }

}
